package com.ruoyi.report.forms.service.impl;

import java.util.List;
import com.ruoyi.common.core.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.report.forms.mapper.ReportFormsTemplateMapper;
import com.ruoyi.report.forms.domain.ReportFormsTemplate;
import com.ruoyi.report.forms.service.IReportFormsTemplateService;

/**
 * 【请填写功能名称】Service业务层处理
 * 
 * @author ruoyi
 * @date 2023-10-30
 */
@Service
public class ReportFormsTemplateServiceImpl implements IReportFormsTemplateService 
{
    @Autowired
    private ReportFormsTemplateMapper reportFormsTemplateMapper;

    /**
     * 查询【请填写功能名称】
     * 
     * @param templateId 【请填写功能名称】主键
     * @return 【请填写功能名称】
     */
    @Override
    public ReportFormsTemplate selectReportFormsTemplateByTemplateId(String templateId)
    {
        return reportFormsTemplateMapper.selectReportFormsTemplateByTemplateId(templateId);
    }

    /**
     * 查询【请填写功能名称】列表
     * 
     * @param reportFormsTemplate 【请填写功能名称】
     * @return 【请填写功能名称】
     */
    @Override
    public List<ReportFormsTemplate> selectReportFormsTemplateList(ReportFormsTemplate reportFormsTemplate)
    {
        return reportFormsTemplateMapper.selectReportFormsTemplateList(reportFormsTemplate);
    }

    /**
     * 新增【请填写功能名称】
     * 
     * @param reportFormsTemplate 【请填写功能名称】
     * @return 结果
     */
    @Override
    public int insertReportFormsTemplate(ReportFormsTemplate reportFormsTemplate)
    {
        reportFormsTemplate.setCreateTime(DateUtils.getNowDate());
        return reportFormsTemplateMapper.insertReportFormsTemplate(reportFormsTemplate);
    }

    /**
     * 修改【请填写功能名称】
     * 
     * @param reportFormsTemplate 【请填写功能名称】
     * @return 结果
     */
    @Override
    public int updateReportFormsTemplate(ReportFormsTemplate reportFormsTemplate)
    {
        reportFormsTemplate.setUpdateTime(DateUtils.getNowDate());
        return reportFormsTemplateMapper.updateReportFormsTemplate(reportFormsTemplate);
    }

    /**
     * 批量删除【请填写功能名称】
     * 
     * @param templateIds 需要删除的【请填写功能名称】主键
     * @return 结果
     */
    @Override
    public int deleteReportFormsTemplateByTemplateIds(String[] templateIds)
    {
        return reportFormsTemplateMapper.deleteReportFormsTemplateByTemplateIds(templateIds);
    }

    /**
     * 删除【请填写功能名称】信息
     * 
     * @param templateId 【请填写功能名称】主键
     * @return 结果
     */
    @Override
    public int deleteReportFormsTemplateByTemplateId(String templateId)
    {
        return reportFormsTemplateMapper.deleteReportFormsTemplateByTemplateId(templateId);
    }
}
